ComponentOne Basic Library for UWP
Basic Library Overview / Radial Menu for UWP / WorkingwithC1Radial Menu / C1RadialMenuItem and C1RadialPanel Elements
In This Topic
    C1RadialMenuItem and C1RadialPanel Elements
    In This Topic

    There are a few properties that are used to draw the geometrical paths in the C1RadialMenuItem default control template. By default, these properties are set by the C1RadialPanel, but you can use them to create custom control templates by setting them explicitly in the C1RadialPanel.

     

     

    C1RadialMenuItem Elements

    The C1RadialMenuItem elements are set by the C1RadialPanel by default. They draw the geometric paths in the C1RadialMenuItem control. The default control template uses them, and you can also use them in custom control templates.

    The CenterPoint property gets the coordinates of the circle's center. This can be used to draw the circle sector in XAML, representing the current C1RadialMenuItem.

    The CheckArc property gets the definition of the check arc segment.

    The ExpandArc property gets the definition of the expand area arc segment.

    The OuterArc property gets the definition of the outer arc segment. This can be used to draw the circle sector in XAML, representing the current C1RadialMenuItem.

    C1RadialPanel Elements

    The C1RadialPanel is created in the default C1RadialMenu style. It's used by the  C1RadialMenuItemsPresenter as an ItemsPanel. The C1RadialPanel makes use of all 360 degrees available to it so that radial menu items are arranged within the circle. If you need to change the StartAngle or EndAngle, then you can use XAML like the following to redefine the default style and use custom settings:

    Markup
    Copy Code
    <Setter Property="ItemsPanel">
       <Setter.Value>
         <ItemsPanelTemplate>
           <c1:C1RadialPanel StartAngle="-180" EndAngle="180" />
         </ItemsPanelTemplate>
       </Setter.Value>
     </Setter>
    

    The StartAngle defines the place where the first C1RadialMenuItem should be located. In the sample above, -180 corresponds to 9 o'clock on a clock face.  This is the default StartAngle.

    The EndAngle defines the place where the last C1RadialMenuItem should be located. In the sample above, 180 corresponds to 9 o'clock on a clock face. This is the default EndAngle. Starting and ending the sweep of the angle at a similar point ensures that the menu items will be arranged properly around the C1RadialMenu.

    See Also